package org.swim.remote.manager;

import java.util.List;

import javax.ejb.Remote;

import net.sf.json.JSONObject;

import org.swim.remote.entities.IEntity;
import org.swim.remote.exceptions.SwimException;

@Remote
public interface SwimEntityManager<T extends IEntity> {

	/*
	 * Post on the database without any control
	 */
	@Deprecated
	public T post(JSONObject json);

	/*
	 * Delete on the database without any control
	 */
	@Deprecated
	public T delete(Integer id);

	/*
	 * Put on the database without any control
	 */
	@Deprecated
	public T put(JSONObject json);

	public T get(Integer id) throws SwimException;

	public List<T> getAll();
}